package com.lovegu.spring.proxy;

/**
 * @author 老顾
 * @title: Proxy
 * @projectName java-restudy
 * @email: 1437594522@qq.com
 * @date 2022/9/25 14:23
 */
public class Proxy implements Rent{
    private Host host;

    public Proxy() {
    }
    public Proxy(Host host) {
        this.host = host;
    }

    /**
     * rent()方法表示租房的方法
     */
    @Override
    public void rent() {
        host.rent();
    }

    /**
     * 定义一个seeHouse()看房方法
     * */
    public void seeHouse(){
        System.out.println("中介带你看房");
    }
    //中介收中介费
    public void fare(){
        System.out.println("收中介费");
    }
    //中介签订租赁合同
    public void lease(){
        System.out.println("签租赁合同");
    }
}
